<extend name="Public:base" />
<block name="main">
	<div class="content">
		<section class="location">
			<i class="iconfont">&#xe60f</i> 位置：<a href="{:U('Index/main')}">管理首页</a> &gt; 管理员列表
		</section>
		<ul class="nav-tabs clearfix">
			<li><a href="{:U('password')}">修改密码</a></li>
			<li class="active">管理员列表</li>
			<li><a href="{:U('add')}">新增管理员</a></li>
		</ul>
		<form method="post" name="list">
			<input type="hidden" name="class" id="class" value="{$Think.CONTROLLER_NAME}" />
			<table width="100%" border="0" cellspacing="0" cellpadding="0" class="table table-hover">
				<thead>
					<tr>
						<th>登录ID</th>
						<th>笔名</th>
						<th>级别</th>
						<th>上次登录时间</th>
						<th>上次登录IP</th>
						<th width="150">操作</th>
					</tr>
				</thead>
				<tbody>
					<volist name="viewList" id="data" empty="暂时没有数据">
					<tr>
						<td><a href="{:U('edit',array('id'=>$data[id]))}">{$data.username}</a></td>
						<td>{$data.author}</td>
						<td>
							<switch name="data.usertype">
								<case value="2">管理员</case>
								<case value="3">频道管理员</case>
							</switch>
						</td>
						<td>{:SearchAll('Adminlog','username',$data['username'],'last_time')}</td>
						<td>{:SearchAll('Adminlog','username',$data['username'],'source')}</td>
						<td><a href="{:U('edit',array('id'=>$data[id]))}">编辑</a> | <a href="javascript:;" data-id="{$data[id]}" data-url="__URL__" class="delete">删除</a></td>
					</tr>
					</volist>
				</tbody>
			</table>
			<div class="pages">{$pages}</div>
		</form>
	</div>
</block>